for a in range(1,10):
    for b in range(1,10):
        for c in range(1,10):
            i=a*100+b*10+c
            if i==a**3+b**3+c**3:
                print(f"{i}是水仙花数")
